package cn.com.pc.penguin.core;

import org.apache.lucene.document.FieldSelector;
import org.apache.lucene.document.FieldSelectorResult;

public class IDFieldSelector implements FieldSelector {

	private static final long serialVersionUID = 4713735152235429280L;

	public FieldSelectorResult accept(String fieldName) {
		if("id".equals(fieldName)) {
			return FieldSelectorResult.LOAD;
		} else {
			return FieldSelectorResult.LAZY_LOAD;
		} 
	}
}
